<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>首页</title>
</head>
<body>
    <h2>诗歌首页</h2>
        <table border="1">
            <thead>
                <tr>
                    <th>标题</th>
                    <th>操作</th>
                </tr>
            </thead>
            <tbody>
                {% for poem in poems %}
                <tr>
                    <td>{{ poem.title }}</td>
                    <td>
                        <a href="{% url 'edit' poem.id %}">编辑</a>
                        <a href="{% url 'delete' poem.id %}">删除</a>
                    </td>
                </tr>
                {% endfor %}
            </tbody>

        </table>
        
    <a href="{% url 'add' %}">添加诗歌</a>
        





</body>
</html>